package cn.webestar.scms.user.entity;

import cn.webestar.scms.commons.entity.BasicDO;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import java.util.Date;

@Data
@Accessors(chain = true)
@EqualsAndHashCode(callSuper = false)
@TableName(value = "t_log", autoResultMap = true)
@Schema(name = "Log", description = "租户日志")
public class Log extends BasicDO<Long> {

    @TableField("cid")
    @Schema(description = "租户id")
    private Long cid;

    @TableField("actor")
    @Schema(description = "事件触发者")
    private String actor;

    @TableField("actor_ip")
    @Schema(description = "触发者ip")
    private String actorIp;

    @TableField("actor_type")
    @Schema(description = "触发者类型，1：系统，2：员工，3：用户")
    private Integer actorType;

    @TableField("event_time")
    @Schema(description = "事件产生时间")
    private Date eventTime;

    @TableField("event_desc")
    @Schema(description = "事件描述")
    private String eventDesc;

    @TableField("create_time")
    @Schema(description = "创建时间")
    private Date createTime;

}